package com.yungu.swift.api.route.v2.passenger;

import com.alibaba.dubbo.config.annotation.Reference;
import com.yungu.swift.assets.passenger.model.dto.PassengerMessageDto;
import com.yungu.swift.assets.passenger.model.param.ApiPassengerMsgParam;
import com.yungu.swift.assets.passenger.service.PassengerMessageService;
import com.yungu.swift.base.ResponseData;
import com.yungu.swift.base.model.annotation.ResponseImgOverride;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;

/**
 * @author : cuixiuyin
 * @date : 2019/11/20
 */
@RestController
@RequestMapping(value = "/api/v2/passenger/token/message")
@Api(value = "【乘客】【消息】乘客消息中心接口V2", tags = "V2-乘客消息中心接口")
public class PasMsgApi {

    @Reference
    private PassengerMessageService passengerMessageService;

    @ResponseImgOverride
    @PostMapping(value = {"/list"})
    @ApiOperation(value = "获取乘客信息中心列表接口", notes = "获取乘客信息中心列表接口")
    public ResponseData<List<PassengerMessageDto>> pasMsgList(@RequestBody ApiPassengerMsgParam passengerMsgParam) {
        return passengerMessageService.queryPasMsgList(passengerMsgParam);
    }

}
